<?php if(!defined('DB_NAME')) die()?>
<?php get_header()?>
<?php if( ismobile() ) ini_map()?>
	<div id="content">
<?php if( ismobile() ){
	echo '		<div class="post-list">';
} else {
	echo '		<div class="main">';
}
if( !ismobile() ) ini_map();
if( get('ini_ad1') && ( !ismobile() || get('ini_mad') ) ) echo "<div class=\"ad1\">".get('ini_ad1_code')."</div>\n";
if ( have_posts()):
	while (have_posts() ): the_post();
		if(ismobile()){
			include 'mp/article.php';
		} else {
			include 'inc/article.php';
		}
	endwhile;
else:
?>
			<div class="context<?php if(ismobile()) echo " search"?>">
				<p style="font:72px/72px '';margin:25px 30px 40px">:(</p>
				<p style="font-size:18px;color:#E63;padding:10px"><strong>您搜索的内容太深奥啦，本站暂时未收录...</strong><br>O(∩_∩)O 随便看看：</p>
				<ul class="tab_post_links">
<?php
$myposts = get_posts("numberposts=8&orderby=rand");
foreach($myposts as $post) :
	echo "					<li><a href=\"".get_permalink( $post->ID )."\" rel=\"bookmark external\">".$post->post_title."</a></li>\n";
endforeach;
?>
				</ul>
			</div>
<?php endif;
if( !ismobile() || get('ini_mad') ){ if( get('ini_ad2') ) echo "<div class=\"ad2\">".get('ini_ad2_code')."</div>\n";}
if( ismobile() ): echo "</div></div><div id='pagination'>".get_next_posts_link(__('浏览更多'))."</div>";
else: pagination( $query_string, $posts_per_page); echo "		</div>\n	</div>\n";
endif;
?>
<?php get_sidebar()?>
<?php get_footer()?>